<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
    <style>
         div{
            width: 100px;
            height: 100px;
            background-color: yellowgreen;
        }
    </style>
</head>
<body>
    <div>111</div>
    <ul>
        <li>111</li>
        <li>222</li>
        <li>333</li>
    </ul>

    <script>
        const divObj = document.querySelector("div")
        const ulObj = document.querySelector("ul")
        divObj.addEventListener("click",function(e){
            console.log(e.type);            //click  打印事件的类型
            // console.log(e.target)           //<li>111</li>    打印事件本身
            // console.log(this)               //<li>111</li>
            // console.log(e.currentTarget);
           
        })

        ulObj.addEventListener("click",function(e){
            console.log(this)       //ul....ul
            console.log(e.target)       //点击的具体的li元素
            console.log(e.currentTarget);   //等价于 this
        })
        
    </script>
</body>
</html>